<template>
	<!-- <view>电脑值不了上面钱了</view> -->
	<view :style="{paddingTop: top +'px'}">
		<uni-nav-bar>
			<block slot="left">
				<view @click="back()" class="city">
					<uni-icons class="input-uni-icon" type="left" size="18" color="#999" />
				</view>
			</block>
			<view class="input-view">
				<text>
					<slot name="text"></slot>
				</text>
				<image class="image" src="../../static/logo.png" mode="widthFix"></image>
			</view>
		</uni-nav-bar>
	</view>
</template>

<script>
	import { mapState } from 'vuex';
	export default {
		//通过计算属性获取值
		computed: {
		...mapState(['top'])
		  },
		data() {
			return {
				// top: ''
			}
		},
		methods: {
			back() {
				uni.navigateBack()
			},
		},
		mounted() {

		}

	}
</script>

<style lang="scss">
	$nav-height: 50px;
	$nav-color: #fff;

	/deep/ .uni-navbar__header[data-v-4e85c420] {
		background-color: $nav-color !important;
	}

	// .uni-navbar__header{
	// 	background-color: $nav-color;
	// }
	/deep/ .uni-navbar--border[data-v-4e85c420] {
		background-color: $nav-color !important;
		border-bottom-color: $nav-color !important;
	}

	.uni-group {
		display: flex;
		align-items: center;
		background-color: $nav-color;
	}

	.input-view {
		// background-color: $nav-color;
		display: flex;
		/* #endif */
		flex-direction: row;
		justify-content: center;
		align-items: center;
		// width: 500rpx;
		flex: 1;
		// background-color: #f8f8f8;
		// height: $nav-height;
		// border-radius: 15px;xxx
		padding: 0 15px;

		flex-wrap: nowrap;
		// margin: 7px 0;
		// line-height: $nav-height;

		.image {
			width: 130rpx;
			margin: 0 10px;
		}

		text {
			font-size: 25rpx;
		}
	}
</style>